home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part2 / 12408 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  2.2 KB

  1. Path: solon.com!not-for-mail
  2. From: seebs@solutions.solon.com (Peter Seebach)
  3. Newsgroups: comp.lang.ada,comp.lang.c,comp.lang.c++
  4. Subject: Re: C/C++ knocks the crap out of Ada
  5. Date: 19 Mar 1996 15:34:01 -0600
  6. Organization: Usenet Fact Police (Undercover)
  7. Message-ID: <4in989$j13@solutions.solon.com>
  8. References: <00001a73+00002504@msn.com> <Do9tMv.2p3@world.std.com> <4ia41k$e04@solutions.solon.com> <1996Mar19.175606.5918@nosc.mil>
  9. NNTP-Posting-Host: solutions.solon.com
  10.  
  11. In article <1996Mar19.175606.5918@nosc.mil>,
  12. Charles H. Sampson <sampson@nosc.mil> wrote:
  13. >In article <4ia41k$e04@solutions.solon.com>,
  14. >Peter Seebach <seebs@solutions.solon.com> wrote:
  15.  
  16. >>To be specific, C compilers are required to tell you about *some*
  17. >>inconsistencies.  There's a clever trick with externs that lets you get
  18. >>this checking, and have the diagnostic be required.
  19.  
  20. >     I know I'm showing my ignorance of vanilla flavored C, but I find
  21. >this a surprising statement.  C compilers are _required_ to tell the
  22. >user something and there's a clever trick to get the C compiler to do
  23. >what it's required to do.  Is this a meaning of _required_ that I'm not
  24. >aware of?
  25.  
  26.  
  27. No.  It's like this; C compilers are required to detect conflicting
  28. definitions.  If you maintain version information in files of the sort that a
  29. C compiler will detect if it is in conflict, you can cause the C compiler's
  30. required diagnostics to apply to your files, as long as the versioning info is
  31. maintained.
  32.  
  33. Not as good as "real" versioning, but cheap.  :)
  34.  
  35. >     I can understand a command line switch that affects this required
  36. >reporting, although my preferred implementation would be to get the mes-
  37. >sages by default and use the switch to suppress them.  However, to have
  38. >to use a trick to obtain required behaviour seems bizarre, even for the
  39. >C world.  Can you elaborate?
  40.  
  41. Sure.  Basically, you provide version based definitions, so any conflict will
  42. cause a diagnostic.
  43.  
  44. -s
  45. -- 
  46. Peter Seebach - seebs@solon.com - Copyright 1996 Peter Seebach.
  47. C/Unix wizard -- C/Unix questions? Send mail for help.  No, really!
  48. FUCK the communications decency act.  Goddamned government.  [literally.]
  49. The *other* C FAQ - http://www.solon.com/~seebs/c/c-iaq.html
  50.